//#include "stdafx.h"
#include "CppUnitTest.h"
#include"../add/myfunction.h"
#include"../static_sub/mysub.h"
#include"../dynamic_mul/mymul.h"
#include "../dynamic_div/div.h"

using namespace Microsoft::VisualStudio::CppUnitTestFramework;

namespace UnitTest1
{		
	TEST_CLASS(UnitTest1)
	{
	public:
		
		TEST_METHOD(TestMethod1)
		{
			Assert::AreEqual((float)add(2.2, -1.0), (float)1.2);
			Assert::AreEqual(add(1, 2), (float)3);

		}
		TEST_METHOD(TestMethod2)
		{
			Assert::AreEqual(sub(-2.3, 2), (float)-4.3);
			Assert::AreEqual(sub(1, 2), (float)-1);
		}
		TEST_METHOD(TestMethod3)
		{
			Assert::AreEqual(mul(-4.4, 2), (float)-8.8);
			Assert::AreEqual(mul(1, 2), (float)2);
			Assert::AreEqual(mul(-4.4, 0), (float)0);
		}
		TEST_METHOD(TestMethod4)
		{
			Assert::AreEqual(Div(0, 2), (float)0);
			Assert::AreEqual(Div(8, 4), (float)2);
			Assert::AreEqual(Div(-6.6, 3.3), (float)-2);
		}



	};
}